#include<bits/stdc++.h>
using namespace std;
#define ll long long
ll n;
ll a[100005];
ll ans,sum,cnt;
int main(){
	freopen("duel.in","r",stdin);
	freopen("duel.out","w",stdout);
	scanf("%lld",&n);
	for(ll i=1;i<=n;i++) scanf("%lld",&a[i]);
	sort(a+1,a+n+1);ans=n;
	for(ll i=1;i<=n;i++){
		if(a[i]==a[i-1]){
			sum++;
			if(cnt) cnt--,ans--;
		}
		else{
			cnt+=sum;sum=1;
			if(cnt) cnt--,ans--;
		}
	}
	printf("%lld\n",ans);
	return 0;
}
